home *** CD-ROM | disk | FTP | other *** search
/ Adobe Digital Video Collection / Digital Video Collection CD.iso / After Effects 5.5 / MMScriptEng.Cab / F115584_scaleall.mm < prev    next >
Encoding:
Text File  |  2001-12-07  |  916 b   |  21 lines

  1. // Scale all layers - version 1.0
  2.  
  3. // This script will scale all layers in the comp by the scale_factor, below.
  4. // It rescales position and scale. This is particularly useful if you resize a
  5. // comp, and want to scale all of your objects to fit it's new dimensions.
  6.  
  7. //      LAYER                                               PROPERTY                     CHANNEL
  8. //      ------                                              ----------                     --------
  9. // 1: doesn't matter                               doesn't matter               doesn't matter
  10. // 2: doesn't matter                               doesn't matter               doesn't matter
  11.  
  12. scale_factor = 0.5;    // change this to your new scale factor
  13. l = 1;
  14. while (l <= num_layers) {    // loop over every layer
  15.  
  16.     value(l, position) = value(l, position) * scale_factor;
  17.     value(l, scale) = value(l, scale) * scale_factor;
  18.  
  19.   l = l+1;
  20. }
  21.